package com.mercury.ec.module.air.service.demandorder;

import com.mercury.ec.framework.common.pojo.PageResult;
import com.mercury.ec.module.air.controller.admin.demandorder.vo.demandorder.*;

import javax.validation.Valid;
import java.util.Map;

/**
 * 机票需求订单 Service 接口
 *
 * @author hesx
 */
public interface AirDemandOrderService {

    /**
     * 创建机票需求订单
     *
     * @param createReqVO 创建信息
     * @return 编号
     */
    Long createAirDemandOrder(@Valid AirDemandOrderCreateReqVO createReqVO);

    /**
     * 更新机票需求订单
     *
     * @param updateReqVO 更新信息
     */
    void updateAirDemandOrder(@Valid AirDemandOrderUpdateReqVO updateReqVO);

    /**
     * 提交机票需求订单
     *
     * @param submitReqVO
     */
    void submitAirDemandOrder(@Valid AirDemandOrderSubmitReqVO submitReqVO);

    /**
     * 取消机票需求订单
     *
     * @param cancelReqVO
     */
    void cancelAirDemandOrder(@Valid AirDemandOrderCancelReqVO cancelReqVO);

    /**
     * 锁定机票需求订单
     *
     * @param lockReqVO
     */
    void lockAirDemandOrder(@Valid AirDemandOrderLockReqVO lockReqVO);

    /**
     * 解锁机票需求订单
     *
     * @param lockReqVO
     */
    void unlockAirDemandOrder(@Valid AirDemandOrderLockReqVO lockReqVO);

    /**
     * 机票需求订单报价
     *
     * @param quoteReqVO
     */
    void quoteAirDemandOrder(@Valid AirDemandOrderQuoteReqVO quoteReqVO);

    /**
     * 机票需求订单核价
     *
     * @param pricingReqVO
     */
    void pricingAirDemandOrder(@Valid AirDemandOrderPricingReqVO pricingReqVO);

    /**
     * 删除机票需求订单
     *
     * @param id 编号
     */
    void deleteAirDemandOrder(Long id);

    /**
     * 获得机票需求订单
     *
     * @param id 编号
     * @return 机票需求订单
     */
    AirDemandOrderRespVO getAirDemandOrder(Long id);

    /**
     * 获得机票需求订单分页
     *
     * @param pageReqVO 分页查询
     * @return 机票需求订单分页
     */
    PageResult<AirDemandOrderRespVO> getAirDemandOrderPage(AirDemandOrderPageReqVO pageReqVO);

    /**
     * 获得机票需求订单按状态分类汇总
     *
     * @param pageReqVO
     * @return
     */
    Map<Integer, Long> getAirDemandOrderCountByStatus(AirDemandOrderPageReqVO pageReqVO);

}
